package com.formulas.certification.dto.data;

import com.fasterxml.jackson.annotation.JsonIgnore;
import com.formulas.component.dto.DTO;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * @author yiwannuofulasi
 * @date 2023/6/13 10:47
 */
@Schema(description = "授权客户端基本信息")
@EqualsAndHashCode(callSuper = true)
@Data
public class OauthClientDetailsDTO extends DTO {

    @Schema(description = "客户端唯一标识")
    @JsonIgnore
    private String clientId;

    @Schema(description = "资源服务器唯一标识")
    private String resourceIds;

    @Schema(description = "客户端密码;不可逆加密")
    private String clientSecret;

    @Schema(description = "用来限制客户端访问的权限;空格隔开")
    private String scope;

    @Schema(description = "授权类型;逗号分隔")
    private String authorizedGrantTypes;

    @Schema(description = "web服务重定向地址")
    private String webServerRedirectUri;

    @Schema(description = "用来限制客户端访问的权限")
    private String authorities;

    @Schema(description = "token有效时间")
    private Integer accessTokenValidity;

    @Schema(description = "token刷新时间;设置时>=2*token有效时间")
    private Integer refreshTokenValidity;

    @Schema(description = "客户端描述信息;若设置必须是JSON格式的数据")
    private String additionalInformation;

    @Schema(description = "自动授权;true即可")
    private String autoapprove;

    @Schema(description = "应用名称")
    private String clientName;

}
